/*
 * Copyright 2009 Google Inc.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
 * use this file except in compliance with the License. You may obtain a copy of
 * the License at
 * 
 * http://www.apache.org/licenses/LICENSE-2.0
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
 * License for the specific language governing permissions and limitations under
 * the License.
 */

package com.google.android.apps.mytracks.content;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * A investigado.
 * 
 * @author Leif Hendrik Wilden
 * @author Rodrigo Damazio
 */
public final class Investigado implements Parcelable {

  private long id = -1L;
  private String nombre = "";
  private String direccion = "";
  private String email = "";
  private long casoId = 1L;


  public Investigado() {}
  
  public Investigado(long id){
    this.id = id;
  }
  
  public Investigado(String nombre, String direccion, String email) {
    this.nombre = nombre;
    this.direccion = direccion;
    this.email = email;
  }
  
  public Investigado(Long investigadoId, String nombre, String direccion, String email) {
    this.id = investigadoId;
    this.nombre = nombre;
    this.direccion = direccion;
    this.email = email;
  }

  private Investigado(Parcel source) {
    id = source.readLong();
    nombre = source.readString();
    direccion = source.readString();
    email = source.readString();
    casoId = source.readLong();
  }

  @Override
  public int describeContents() {
    return 0;
  }

  @Override
  public void writeToParcel(Parcel dest, int flags) {
    dest.writeLong(id);
    dest.writeString(nombre);
    dest.writeString(direccion);
    dest.writeString(email);
    dest.writeLong(casoId);
    }

  public static final Parcelable.Creator<Investigado> CREATOR = new Parcelable.Creator<Investigado>() {
      @Override
    public Investigado createFromParcel(Parcel in) {
      return new Investigado(in);
    }

      @Override
    public Investigado[] newArray(int size) {
      return new Investigado[size];
    }
  };

  public long getId() {
    return id;
  }

  public void setId(long id) {
    this.id = id;
  }

  public String getNombre() {
    return nombre;
  }

  public void setNombre(String nombre) {
    this.nombre = nombre;
  }

  public String getDireccion() {
    return direccion;
  }

  public void setDireccion(String direccion) {
    this.direccion = direccion;
  }

  public String getEmail() {
    return email;
  }

  public void setEmail(String email) {
    this.email = email;
  }

  public long getCasoId() {
    return casoId;
  }

  public void setCasoId(long casoId) {
    this.casoId = casoId;
  }
}
